import http from '@/utils/request';

export default {
  /**
   * 查询菜单列表
   * @param params
   * @returns {Promise<AxiosResponse<any>>}
   */
  async getMenuList(params){
    return await http.get('/api/permission/list',params);
  },
  //菜单树数据
  async getMenuTree(){
    return await http.get('/api/permission/parent/list');
  },
  //新增
  async addMenu(params){
    return await http.post("/api/permission/add",params);
  },
  //编辑
  async updateMenu(params){
    return await http.put("/api/permission/update",params);
  }
}
